package com.action;

import javax.servlet.http.HttpSession;

import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Controller;

import com.opensymphony.xwork2.ActionSupport;
import com.po.User;
import com.service.UserService;

@Controller
@Scope("prototype")
public class UserAction extends BaseAction {
	
	private User user;
	
	public String login(){
		if(this.userService.check(user)&&user.getPermission()!=null){
			return SUCCESS;
		}else {
			return INPUT;
		}
	}

	public User getUser() {
		return user;
	}

	public void setUser(User user) {
		this.user = user;
	}
}
